home *** CD-ROM | disk | FTP | other *** search
- //////////
- //
- // File: AddVRActions.h
- //
- // Contains: Sample code for adding wired actions to a QuickTime VR movie.
- //
- // Written by: Tim Monroe
- // Based on existing code by Bill Wright
- //
- // Copyright: © 1999 by Apple Computer, Inc., all rights reserved.
- //
- // Change History (most recent first):
- //
- // <1> 07/14/99 rtm first file from bw
- //
- //////////
-
-
- //////////
- //
- // header files
- //
- //////////
-
- #ifndef __MACTYPES__
- #include <MacTypes.h>
- #endif
-
- #ifndef __ENDIAN__
- #include <Endian.h>
- #endif
-
- #ifndef __MOVIES__
- #include <Movies.h>
- #endif
-
- #ifndef __MACMEMORY__
- #include <MacMemory.h>
- #endif
-
- #ifndef _STRING_H
- #include <string.h>
- #endif
-
- #ifndef __FONTS__
- #include <Fonts.h>
- #endif
-
- #ifndef __MOVIES__
- #include <Movies.h>
- #endif
-
- #ifndef __FIXMATH__
- #include <FixMath.h>
- #endif
-
- #ifndef __QUICKTIMEVRFORMAT__
- #include <QuickTimeVRFormat.h>
- #endif
-
- #ifndef __QUICKTIMEVR__
- #include <QuickTimeVR.h>
- #endif
-
- // Windows-specific header files
- #if TARGET_OS_WIN32
-
- #ifndef __QTML__
- #include <QTML.h>
- #endif
-
- #include <windows.h>
-
- #endif
-
-
- //////////
- //
- // constants
- //
- //////////
-
- #define kIndexZero 0
- #define kIndexOne 1
- #define kZeroDataLength 0
-
-
- //////////
- //
- // function prototypes
- //
- //////////
-
- static OSErr AddVRAct_GetFirstHotSpot (Handle theSample, long *theHotSpotID);
- static OSErr AddVRAct_CreateHotSpotActionContainer (QTAtomContainer *theActions);
- static OSErr AddVRAct_CreateFrameLoadedActionContainer (QTAtomContainer *theActions);
- static OSErr AddVRAct_SetFrameLoadedWiredActions (Handle theSample, QTAtomContainer theActions);
- static OSErr AddVRAct_SetWiredActionsToHotSpot (Handle theSample, long theHotSpotID, QTAtomContainer theActions);
- static OSErr AddVRAct_WriteMediaPropertyAtom (Media theMedia, long thePropertyID, long thePropertySize, void *theProperty);
- static void AddVRAct_AddWiredActionsToQTVRMovie (FSSpec *theFSSpec);
- static void AddVRAct_ConvertFloatToBigEndian (float *theFloat);
-